
#include "stdafx.h"
#include "WicBitmapDecoderInfo.h"

CWicBitmapDecoderInfo::CWicBitmapDecoderInfo()
{
    m_pIWICBitmapDecoderInfo = NULL;
}

CWicBitmapDecoderInfo::~CWicBitmapDecoderInfo()
{
    if(m_pIWICBitmapDecoderInfo)
    {
        m_pIWICBitmapDecoderInfo->Release();
    }
    m_pIWICBitmapDecoderInfo = NULL;
}

CWicBitmapDecoderInfo::CWicBitmapDecoderInfo(CWicBitmapDecoderInfo const & objBitmapDecoderInfo)
{
    m_pIWICBitmapDecoderInfo = objBitmapDecoderInfo.m_pIWICBitmapDecoderInfo;
    m_pIWICBitmapDecoderInfo->AddRef();
}

CWicBitmapDecoderInfo& CWicBitmapDecoderInfo::operator=(CWicBitmapDecoderInfo const & objBitmapDecoderInfo)
{
    if(m_pIWICBitmapDecoderInfo)
    {
        m_pIWICBitmapDecoderInfo->Release();
    }
    m_pIWICBitmapDecoderInfo = objBitmapDecoderInfo.m_pIWICBitmapDecoderInfo;
    m_pIWICBitmapDecoderInfo->AddRef();
    return *this;
}
